(function() {
	var _ = require(L('_'));

	var view = Ti.UI.createTabGroup({
		allowUserCustomization : true,
		activeTab : 0
	});
	var wins = ['my_desires', 'my_cart', 'purchase', 'notifications', 'my_account'];
	_.each(wins, function(name) {
		view.addTab(Ti.UI.createTab({
			title : '',
			window : $.win(name),
		}));
	});
	view.reset = function() {
		$.win('my_desires').reset();
	};

	view.add($.ui('bottom'));
	view.addEventListener('focus', function(e) {
		if (e.tab)
			Ti.UI.currentTab = e.tab;
		$.ui('bottom').update_badge();
	});
	view.addEventListener('click', function(e) {
	});

	module.exports = view;
})();
